#include <iostream>

void PrintBinary(int num){
    for (int i=31; i>=0; i--){
        std::cout << ((num & (1 << i))==0 ? "0" : "1");
    }
    std::cout << std::endl;
}

int main(){

		int g = 0b0001010;
		int h = 0b0001100;

		PrintBinary(g | h);

		PrintBinary(g & h);

		PrintBinary(g ^ h);
        
    return 0;
}